package com.gs.jmx;

public class JmxBean {
	private String name;
	private int age;
	private String description;
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	public int getAge() {
		return age;
	}
	public void setAge(int age) {
		System.out.println("Changing description...");
		setDescription(name + " " + age + " years old.");
		this.age = age;
	}
	public String getDescription() {
		return description;
	}
	public void setDescription(String description) {
		this.description = description;
	}
	public int add(int x,int y){
		return x+y;
	}
	public void dontExposeMe() {
        throw new RuntimeException();
    }
	@Override
	public String toString() {
		return "JmxBean [name=" + name + ", age=" + age + ", description="
				+ description + "]";
	}	
}
